import type { Params } from "@/types/common"
import { $lvAppApi } from "@/utils/http-instance"

// upload to cdn
// postParams: {image_base64, image_file_name}
export const $uploadFile = (queryParams: Params, postParams: Params) => {
	const url = `images/upload?sign=${queryParams.sign}&timestamp=${queryParams.timestamp}`
	return $lvAppApi.post(url, postParams, { no_token: true, no_under_score: true })
}
